const sequelize = require('../db/index');

const getSearchDetail = async (search) => {
  const sql = `select * from goods where goods_name like '%${search}%'`
  const searchGoods = await sequelize.query(sql, { type: sequelize.QueryTypes.SELECT, raw: true })
  return searchGoods
}

module.exports = {
  getSearchDetail
}